package com.sxt.dao;

import java.util.List;

import org.springframework.orm.hibernate3.support.HibernateDaoSupport;

import com.sxt.entity.Message;

public class MessageDao extends HibernateDaoSupport implements BaseDao {

	@SuppressWarnings("unchecked")
	@Override
	public List<Message> getMessages() {
		return super.getHibernateTemplate().find("from Message");
	}

	@Override
	public void addMessage(Message msg) {
		super.getHibernateTemplate().save(msg);
	}
}
